﻿namespace EasyWeb.Web.UI
{
    using System;
    using System.Collections.Generic;
    using System.Linq;
    using System.Text;
    using System.Threading.Tasks;

    public class EWGridStyleBuilder<TModel>
    {
        public EWGridStyleBuilder(EWGrid<TModel> grid)
        {
            EWGuard.IsNotNull(grid, "grid");
            this.Component = grid;
        }

        public EWGrid<TModel> Component { get; private set; }

        public EWGridStyleBuilder<TModel> TableStyle(string value)
        {
            this.Component.TableStyle = value;
            return this;
        }

        public EWGridStyleBuilder<TModel> HeaderStyle(string value)
        {
            this.Component.HeaderStyle = value;
            return this;
        }

        public EWGridStyleBuilder<TModel> FooterStyle(string value)
        {
            this.Component.FooterStyle = value;
            return this;
        }

        public EWGridStyleBuilder<TModel> RowStyle(string value)
        {
            this.Component.RowStyle = value;
            return this;
        }

        public EWGridStyleBuilder<TModel> AlternatingRowStyle(string value)
        {
            this.Component.AlternatingRowStyle = value;
            return this;
        }

        public EWGridStyleBuilder<TModel> SelectedRowStyle(string value)
        {
            this.Component.SelectedRowStyle = value;
            return this;
        }
    }
}
